package com.sentiment.obj;

import java.util.ArrayList;

import org.bson.Document;

public class RalationMap {
	public RalationMap() {
	}

	public RalationMap(String srcId, ArrayList<String> tarIdAll, Integer tarAmount) {
		this.srcId = srcId;
		this.tarIdAll = tarIdAll;
		this.tarAmount = tarAmount;
	}

	public RalationMap(Document doc) {
		this.srcId = doc.getString("srcId");
		this.tarIdAll = (ArrayList<String>) doc.get("tarIdAll");
		this.tarAmount = doc.getInteger("tarAmount");
	}

	/**
	 * 爬取文章总数
	 */
	private Integer tarAmount = 0;
	/**
	 * src 对应用户输入文章的id
	 */
	private String srcId = "null";
	/**
	 * tar 与用户输入文章id对应的爬取文章id
	 */
	private ArrayList<String> tarIdAll = null;

	public void setTarIdAll(ArrayList<String> tarIdAll) {
		this.tarIdAll = tarIdAll;
	}

	public Integer getTarAmount() {
		return tarAmount;
	}

	public void setTarAmount(Integer tarAmount) {
		this.tarAmount = tarAmount;
	}

	public String getSrcId() {
		return srcId;
	}

	public void setSrcId(String srcId) {
		this.srcId = srcId;
	}

	public ArrayList<String> getTarIdAll() {
		return tarIdAll;
	}
}
